Ext.define('Portal.store.NavigationTree', {
    extend: 'Ext.data.TreeStore',
    storeId: 'NavigationTree',
    alias:'store.navigationTree',
    proxy: {
        type: 'ajax',
        url : 'http://localhost:1234/main/nav/get-navlist',
        reader:{
            type:'json'
        },
        extractResponseData: function(response) {
            var json = Ext.JSON.decode(response.responseText);
            console.log(json);


            response.responseText = Ext.JSON.encode(json.root);
            return response;
        }
    },
    autoLoad : true
});
